3.7.47 \(\int \frac {\sqrt {x}}{\sqrt {1-x}} \, dx\)

Optimal. Leaf size=27 \[ -\sqrt {1-x} \sqrt {x}-\frac {1}{2} \sin ^{-1}(1-2 x) \]

________________________________________________________________________________________

Rubi [A]  time = 0.01, antiderivative size = 27, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 15, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.267, Rules used = {50, 53, 619, 216} \begin {gather*} -\sqrt {1-x} \sqrt {x}-\frac {1}{2} \sin ^{-1}(1-2 x) \end {gather*}

Antiderivative was successfully verified.

[In]

Int[Sqrt[x]/Sqrt[1 - x],x]

[Out]

-(Sqrt[1 - x]*Sqrt[x]) - ArcSin[1 - 2*x]/2

Rule 50

Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_), x_Symbol] :> Simp[((a + b*x)^(m + 1)*(c + d*x)^n)/(b*
(m + n + 1)), x] + Dist[(n*(b*c - a*d))/(b*(m + n + 1)), Int[(a + b*x)^m*(c + d*x)^(n - 1), x], x] /; FreeQ[{a
, b, c, d}, x] && NeQ[b*c - a*d, 0] && GtQ[n, 0] && NeQ[m + n + 1, 0] &&  !(IGtQ[m, 0] && ( !IntegerQ[n] || (G
tQ[m, 0] && LtQ[m - n, 0]))) &&  !ILtQ[m + n + 2, 0] && IntLinearQ[a, b, c, d, m, n, x]

Rule 53

Int[1/(Sqrt[(a_) + (b_.)*(x_)]*Sqrt[(c_.) + (d_.)*(x_)]), x_Symbol] :> Int[1/Sqrt[a*c - b*(a - c)*x - b^2*x^2]
, x] /; FreeQ[{a, b, c, d}, x] && EqQ[b + d, 0] && GtQ[a + c, 0]

Rule 216

Int[1/Sqrt[(a_) + (b_.)*(x_)^2], x_Symbol] :> Simp[ArcSin[(Rt[-b, 2]*x)/Sqrt[a]]/Rt[-b, 2], x] /; FreeQ[{a, b}
, x] && GtQ[a, 0] && NegQ[b]

Rule 619

Int[((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_), x_Symbol] :> Dist[1/(2*c*((-4*c)/(b^2 - 4*a*c))^p), Subst[Int[Si
mp[1 - x^2/(b^2 - 4*a*c), x]^p, x], x, b + 2*c*x], x] /; FreeQ[{a, b, c, p}, x] && GtQ[4*a - b^2/c, 0]

Rubi steps

\begin {align*} \int \frac {\sqrt {x}}{\sqrt {1-x}} \, dx &=-\sqrt {1-x} \sqrt {x}+\frac {1}{2} \int \frac {1}{\sqrt {1-x} \sqrt {x}} \, dx\\ &=-\sqrt {1-x} \sqrt {x}+\frac {1}{2} \int \frac {1}{\sqrt {x-x^2}} \, dx\\ &=-\sqrt {1-x} \sqrt {x}-\frac {1}{2} \operatorname {Subst}\left (\int \frac {1}{\sqrt {1-x^2}} \, dx,x,1-2 x\right )\\ &=-\sqrt {1-x} \sqrt {x}-\frac {1}{2} \sin ^{-1}(1-2 x)\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.01, size = 25, normalized size = 0.93 \begin {gather*} -\sqrt {-((x-1) x)}-\sin ^{-1}\left (\sqrt {1-x}\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[Sqrt[x]/Sqrt[1 - x],x]

[Out]

-Sqrt[-((-1 + x)*x)] - ArcSin[Sqrt[1 - x]]

________________________________________________________________________________________

IntegrateAlgebraic [A]  time = 0.08, size = 39, normalized size = 1.44 \begin {gather*} 2 \tan ^{-1}\left (\frac {\sqrt {x}}{\sqrt {1-x}-1}\right )-\sqrt {1-x} \sqrt {x} \end {gather*}

Antiderivative was successfully verified.

[In]

IntegrateAlgebraic[Sqrt[x]/Sqrt[1 - x],x]

[Out]

-(Sqrt[1 - x]*Sqrt[x]) + 2*ArcTan[Sqrt[x]/(-1 + Sqrt[1 - x])]

________________________________________________________________________________________

fricas [A]  time = 1.52, size = 27, normalized size = 1.00 \begin {gather*} -\sqrt {x} \sqrt {-x + 1} - \arctan \left (\frac {\sqrt {-x + 1}}{\sqrt {x}}\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^(1/2)/(1-x)^(1/2),x, algorithm="fricas")

[Out]

-sqrt(x)*sqrt(-x + 1) - arctan(sqrt(-x + 1)/sqrt(x))

________________________________________________________________________________________

giac [A]  time = 1.17, size = 17, normalized size = 0.63 \begin {gather*} -\sqrt {x} \sqrt {-x + 1} + \arcsin \left (\sqrt {x}\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^(1/2)/(1-x)^(1/2),x, algorithm="giac")

[Out]

-sqrt(x)*sqrt(-x + 1) + arcsin(sqrt(x))

________________________________________________________________________________________

maple [A]  time = 0.01, size = 41, normalized size = 1.52 \begin {gather*} -\sqrt {-x +1}\, \sqrt {x}+\frac {\sqrt {\left (-x +1\right ) x}\, \arcsin \left (2 x -1\right )}{2 \sqrt {-x +1}\, \sqrt {x}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x^(1/2)/(1-x)^(1/2),x)

[Out]

-(1-x)^(1/2)*x^(1/2)+1/2*(x*(1-x))^(1/2)/x^(1/2)/(1-x)^(1/2)*arcsin(-1+2*x)

________________________________________________________________________________________

maxima [A]  time = 3.00, size = 37, normalized size = 1.37 \begin {gather*} \frac {\sqrt {-x + 1}}{\sqrt {x} {\left (\frac {x - 1}{x} - 1\right )}} - \arctan \left (\frac {\sqrt {-x + 1}}{\sqrt {x}}\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^(1/2)/(1-x)^(1/2),x, algorithm="maxima")

[Out]

sqrt(-x + 1)/(sqrt(x)*((x - 1)/x - 1)) - arctan(sqrt(-x + 1)/sqrt(x))

________________________________________________________________________________________

mupad [B]  time = 0.57, size = 31, normalized size = 1.15 \begin {gather*} 2\,\mathrm {atan}\left (\frac {\sqrt {x}}{\sqrt {1-x}-1}\right )-\sqrt {x}\,\sqrt {1-x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x^(1/2)/(1 - x)^(1/2),x)

[Out]

2*atan(x^(1/2)/((1 - x)^(1/2) - 1)) - x^(1/2)*(1 - x)^(1/2)

________________________________________________________________________________________

sympy [A]  time = 1.65, size = 54, normalized size = 2.00 \begin {gather*} \begin {cases} - i \sqrt {x} \sqrt {x - 1} - i \operatorname {acosh}{\left (\sqrt {x} \right )} & \text {for}\: \left |{x}\right | > 1 \\\frac {x^{\frac {3}{2}}}{\sqrt {1 - x}} - \frac {\sqrt {x}}{\sqrt {1 - x}} + \operatorname {asin}{\left (\sqrt {x} \right )} & \text {otherwise} \end {cases} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x**(1/2)/(1-x)**(1/2),x)

[Out]

Piecewise((-I*sqrt(x)*sqrt(x - 1) - I*acosh(sqrt(x)), Abs(x) > 1), (x**(3/2)/sqrt(1 - x) - sqrt(x)/sqrt(1 - x)
 + asin(sqrt(x)), True))

________________________________________________________________________________________